home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 5640 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  908 b 

  1. Path: news1.radix.net!news
  2. From: jfw@radix.net (Jim Ward)
  3. Newsgroups: comp.lang.c
  4. Subject: Sorting a directory
  5. Date: 20 Feb 1996 02:27:21 GMT
  6. Organization: RadixNet Internet Services
  7. Message-ID: <4gbbi9$c7s@news1.radix.net>
  8. NNTP-Posting-Host: dialin4.annex1.radix.net
  9. Mime-Version: 1.0
  10. Content-Type: Text/Plain; charset=US-ASCII
  11. X-Newsreader: WinVN 0.99.7
  12.  
  13. I want to retrieve a sorted list of files in a directory.
  14. I am using UNIX, on an HP, and I found by reading the
  15. manpages I could use scandir() and alphasort() to perform the task
  16. (these seem to be old BSD functions). When
  17. I try to move the same code over to a SUN, the linker
  18. (for the SunOS 5.4 cc) can't find these functions. 
  19. Is there a library that I can link with that provides them?
  20. Or have they been dropped as the UNIX world moves from
  21. BSD to System V? Is there something in the C library that
  22. I should be using instead?
  23.  
  24. Sincerely,
  25.  
  26. Jim Ward
  27.  
  28.